home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / mint / mntdoc01.zoo / mintdoc / cat2 / pgetuid.nr < prev    next >
Encoding:
Text File  |  1993-03-03  |  1.6 KB  |  67 lines

  1.  
  2.  
  3.  
  4. Pgetuid(2)                 Aug. 1, 1992                Pgetuid(2)
  5.  
  6.  
  7. N✓NA✓AM✓ME✓E
  8.        Pgetuid, Pgetgid - get the current user or group id
  9.  
  10. S✓SY✓YN✓NO✓OP✓PS✓SI✓IS✓S
  11.        WORD Pgetuid();
  12.        WORD Pgetgid();
  13.        WORD Pgeteuid();
  14.        WORD Pgetegid();
  15.  
  16. D✓DE✓ES✓SC✓CR✓RI✓IP✓PT✓TI✓IO✓ON✓N
  17.        _✓P_✓g_✓e_✓t_✓u_✓i_✓d  returns the real user id of the currently running
  18.        process. This is a number between 0 and 255  which  deter-
  19.        mines the access permissions of the process, and which may
  20.        be used in multi-user  systems  to  distinguish  different
  21.        users of the system.
  22.  
  23.  
  24.        Similarly,  _✓P_✓g_✓e_✓t_✓g_✓i_✓d  returns the real group id of the cur-
  25.        rently running process; this will also be a number between
  26.        0 and 255.
  27.  
  28.  
  29.        _✓P_✓g_✓e_✓t_✓e_✓u_✓i_✓d  and  _✓P_✓g_✓e_✓t_✓e_✓g_✓i_✓d are similar to _✓P_✓g_✓e_✓t_✓u_✓i_✓d and _✓P_✓g_✓e_✓t_✓g_✓i_✓d
  30.        respectively, except that they return the  effective  user
  31.        or  group  id.  This is normally the same as the real user
  32.        or group id, except that if a program is run which has the
  33.        set uid or set gid bit bit set, it will run with an effec-
  34.        tive user or group id equal to the owner  of  the  program
  35.        file.  Access to files is based upon the effective user or
  36.        group id, so the set uid (and set  gid)  mechanism  allows
  37.        users  (in particular the super user) to grant permissions
  38.        to other users. This mechanism also exists in the Unix(tm)
  39.        operating system.
  40.  
  41.  
  42. S✓SE✓EE✓E A✓AL✓LS✓SO✓O
  43.        _✓P_✓s_✓e_✓t_✓u_✓i_✓d(2)
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64. Version 0.95         MiNT Programmer's Manual                   1
  65.  
  66.  
  67.